﻿using Microsoft.Extensions.Options;
using Wx.Standard.IService;
using Wx.Standard.Options;
using Wx.Standard.Service;

namespace Wx.Standard
{
    public class WxApp
    {
        IApp weChatSmallApp = null;

        public AppOption appOption;

        public WxApp(IOptions<AppOption> options)
        {
            this.appOption = options.Value;
        }
        private WxApp()
        {
        }
       
        /// <summary>
        /// 小程序
        /// </summary>
        public IApp App
        {
            get
            {
                if (weChatSmallApp == null)
                {
                    this.weChatSmallApp = new App(this);
                }
                return weChatSmallApp;
            }
        }
    }
}
